import cgi
import urllib

def post_data(url, data):
    response = urllib.urlopen(url, urllib.urlencode(data))
    return cgi.parse_qs(response.read())